package com.firefly.dao.dto.ums;

import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;

/**
 * @description: 更新自己的资料
 * @author: lzg(萤火科技 ： 854378082 @ qq.com)
 * @date: 2022/12/9
 **/
@Data
@EqualsAndHashCode
public class AdminUpdateSelfDto implements Serializable {
    private static final long serialVersionUID = 1L;
    @NotBlank(message = "真实姓名不能为空")
    private String realname;
    @Pattern(regexp = "^([a-zA-Z0-9]*[-_]?[a-zA-Z0-9]+)*@([a-zA-Z0-9]*[-_]?[a-zA-Z0-9]+)+[\\.][A-Za-z]{2,3}([\\.][A-Za-z]{2})?$", message = "邮箱格式")
    private String email;
    @Pattern(regexp = "^1[3456789]\\d{9}$", message = "手机号格式不正确")
    private String phone;
}
